package com.mmy.fta.usercenter.repository;

import com.mmy.fta.usercenter.entity.OpenidUserEntity;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

@Mapper
public interface OpenidUserMapper {
    int insert(OpenidUserEntity record);

    int insertSelective(OpenidUserEntity record);

    OpenidUserEntity selectByPrimaryKey(Long id);

    OpenidUserEntity selectByOpenId(@Param("openId") String openId);

    int updateByPrimaryKeySelective(OpenidUserEntity record);

    int updateByPrimaryKey(OpenidUserEntity record);

    int updateByOpenIdSelective(OpenidUserEntity record);

    int selectDriverMemberShipStatus(String openId);

    int selectShipperMemberShipStatus(String openId);

    int updateColdMemberShipStatus(String openId);

    int updateShipperNormalMemberShipStatus(String openId);

    int updateOilMemberShipStatus(String openId);

    int updateMemberShipStatus(String openId);

    int updateShipperCargoTimes(String openId);

//    boolean ColdMembership();

    String queryShipperIdNo(String openId);

    int selectDriverIsColdMembership(String driverOpenId);

    int selectDriverIsNormalMembership(String driverOpenId);

    int selectShipperIsNormalMembership(String shipperOpenId);

    Integer selectFreetime(String openId);

    int selectCoupons(String openId);

    int updateDriverNormalMemberShipStatus(String openId);

    int decDriverFreeTimesByOpenId(String openId);

    int queryShipperIsColdMember(String openId);

    int updateMsg(OpenidUserEntity openidUserEntity);

    void addShipperSendCargoTimes(String openId);

}